package test3;

public class GirlFriend {
    //创建对象
    private String name;
    private int age;
    private  String hobby;
    //构造
    //空参构造
    public GirlFriend(){

    }
    //实参构造
    public GirlFriend(String name,int age,String hobby){
        this.name=name;
        this.age=age;
        this.hobby=hobby;
    }
    public void setName(String name){
        this.name=name;
    }
    public String getName(){
        return name;
    }
    public void setAge(int age){
        this.age=age;
    }
    public int getAge(){
        return age;
    }
    public void setHobby(String hobby){
        this.hobby=hobby;
    }
    public String getHobby(){
        return hobby;
    }
}
